import html2text
from requests_html import HTMLSession
import pyperclip

'''未读代码'''

path = r'C:\Users\ASUS\Desktop'
session = HTMLSession()
url = pyperclip.paste()
page = session.get(url)
page.encoding = 'utf-8'

content = page.html.find('div.content__default', first=True).html

md = html2text.html2text(content)
with open(path + r'\Java 8 Stream 流式操作.md', 'w', encoding='utf-8') as f:
    f.write(md)